package com.neusoft.bizcore.webauth.secret;

import java.util.Map;

import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

import com.neusoft.bizcore.auth.common.bean.UserBean;
import com.neusoft.bizcore.web.dto.result.ResultDTO;

public interface WebAuthMicroService {
    @RequestMapping(method = RequestMethod.GET, value = "/api/w/auth/users/username/{username}")
    ResultDTO<UserBean> loadUserByUsername(@PathVariable final String username);

    @RequestMapping(method = RequestMethod.POST, value = "/api/w/auth/dingding/login")
    ResultDTO<UserBean> loginByDingUser(@RequestParam final Map<String, String> params);

    @RequestMapping(method = RequestMethod.GET, value = "/api/w/auth/oauth2/{code}")
    ResultDTO<UserBean> loadByOAuth2Code(@PathVariable final String code);
}
